load("@prelude//toolchains/android/tools:build_rules.bzl", "buck_kotlin_library")
load("@prelude//utils:source_listing.bzl", "source_listing")

oncall("android_devxx")

source_listing()

buck_kotlin_library(
    name = "buildtools",
    srcs = glob(["**/*.kt"]),
    extra_kotlinc_arguments = ["-Xopt-in=kotlin.ExperimentalStdlibApi"],
    tests = [
        "prelude//toolchains/android/test/com/facebook/buck/jvm/kotlin/buildtools:buildtools",
    ],
    visibility = [
        "prelude//toolchains/android/src/com/facebook/buck/jvm/kotlin/...",
        "prelude//toolchains/android/test/com/facebook/buck/jvm/kotlin/...",
    ],
    deps = [
        # @oss-disable[end= ]: "fbsource//fbandroid/java/com/facebook/kotlin/compilercompat:compilercompat",
        "prelude//toolchains/android/src/com/facebook/buck/cd/resources/proto:javacd-model",
        "prelude//toolchains/android/src/com/facebook/buck/core/build/execution/context:context",
        "prelude//toolchains/android/src/com/facebook/buck/core/filesystems:filesystems",
        "prelude//toolchains/android/src/com/facebook/buck/core/util/log:log",
        "prelude//toolchains/android/src/com/facebook/buck/jvm/java:support",
        "prelude//toolchains/android/src/com/facebook/buck/jvm/java/javax:javax",
        "prelude//toolchains/android/src/com/facebook/buck/jvm/kotlin/cd/analytics:analytics",
        "prelude//toolchains/android/src/com/facebook/buck/jvm/kotlin/kotlinc:kotlinc",
        "prelude//toolchains/android/src/com/facebook/buck/jvm/kotlin/kotlinc/incremental:incremental",
        "prelude//toolchains/android/third-party:guava",
        "prelude//toolchains/android/third-party:kotlin-build-tools-api",
    ],
)
